Functions | Variables
InterfaceDemo Namespace Reference

Functions

def decoding_char (ctypes_char_array)
 

Variables

 currentsystem = platform.system()
 
 input_func = raw_input
 
 SDKVersion = MvCamera.MV_CC_GetSDKVersion()
 
 interfaceList = MV_INTERFACE_INFO_LIST()
 
 transportLayerType = MV_GIGE_INTERFACE | MV_CAMERALINK_INTERFACE | MV_CXP_INTERFACE | MV_XOF_INTERFACE
 
 ret = MvCamera.MV_CC_EnumInterfaces(transportLayerType, interfaceList)
 
 interfaceInfo = cast(interfaceList.pInterfaceInfos[i], POINTER(MV_INTERFACE_INFO)).contents
 
def displayName = decoding_char(interfaceInfo.chDisplayName)
 
def serialNumber = decoding_char(interfaceInfo.chSerialNumber)
 
def modelName = decoding_char(interfaceInfo.chModelName)
 
def interfaceId = decoding_char(interfaceInfo.chInterfaceID)
 
 nConnectionNum = input_func("please input the number of the interface to connect:")
 
 cam = MvCamera()
 
 curInterface = cast(interfaceList.pInterfaceInfos[int(nConnectionNum)], POINTER(MV_INTERFACE_INFO)).contents
 
 stEnumValue = MVCC_ENUMVALUE()
 

Function Documentation

◆ decoding_char()

def InterfaceDemo.decoding_char (   ctypes_char_array)
Safely decode a string from a ctypes character array.
Compatible with Python 2.x and 3.x, as well as 32-bit and 64-bit environments.

Variable Documentation

◆ currentsystem

currentsystem = platform.system()

◆ input_func

input_func = raw_input

◆ SDKVersion

SDKVersion = MvCamera.MV_CC_GetSDKVersion()

◆ interfaceList

interfaceList = MV_INTERFACE_INFO_LIST()

◆ transportLayerType

transportLayerType = MV_GIGE_INTERFACE | MV_CAMERALINK_INTERFACE | MV_CXP_INTERFACE | MV_XOF_INTERFACE

◆ ret

ret = MvCamera.MV_CC_EnumInterfaces(transportLayerType, interfaceList)

◆ interfaceInfo

interfaceInfo = cast(interfaceList.pInterfaceInfos[i], POINTER(MV_INTERFACE_INFO)).contents

◆ displayName

def displayName = decoding_char(interfaceInfo.chDisplayName)

◆ serialNumber

def serialNumber = decoding_char(interfaceInfo.chSerialNumber)

◆ modelName

def modelName = decoding_char(interfaceInfo.chModelName)

◆ interfaceId

def interfaceId = decoding_char(interfaceInfo.chInterfaceID)

◆ nConnectionNum

nConnectionNum = input_func("please input the number of the interface to connect:")

◆ cam

cam = MvCamera()

◆ curInterface

curInterface = cast(interfaceList.pInterfaceInfos[int(nConnectionNum)], POINTER(MV_INTERFACE_INFO)).contents

◆ stEnumValue

stEnumValue = MVCC_ENUMVALUE()